home *** CD-ROM | disk | FTP | other *** search
Text File | 1996-09-17 | 1.5 KB | 56 lines | [TEXT/MPS ] |
- //========================================================================================
- //
- // File: FWPalete.cpp
- // Release Version: $ ODF 2 $
- //
- // Copyright: (c) 1993 - 1996 by Apple Computer, Inc., all rights reserved.
- //
- //========================================================================================
-
- #include "FWOS.hpp"
-
- #ifndef FWPALETE_H
- #include "FWPalete.h"
- #endif
-
- #ifndef SLPALETE_H
- #include "SLPalete.h"
- #endif
-
- #ifndef SLMEMMGR_H
- #include "SLMemMgr.h"
- #endif
-
- //========================================================================================
- // Palette functions
- //========================================================================================
-
- //----------------------------------------------------------------------------------------
- // FW_CreatePalette
- //----------------------------------------------------------------------------------------
-
- FW_Palette
- FW_CreatePalette(
- const FW_SColor* colors,
- short nColorCount)
- {
- FW_Palette palette = FW_PrivCreatePalette(colors, nColorCount);
- if (palette == NULL)
- FW_Failure(FW_xMemoryExhausted);
- return palette;
- }
-
- //----------------------------------------------------------------------------------------
- // FW_CopyPalette
- //----------------------------------------------------------------------------------------
-
- FW_Palette
- FW_CopyPalette(FW_Palette palette)
- {
- FW_Palette palCopy = FW_PrivCopyPalette(palette);
- if (palCopy == NULL)
- FW_Failure(FW_xMemoryExhausted);
- return palCopy;
- }
-
-